package com.comall.dc.banktest.infrastructure.entity;

import com.baomidou.mybatisplus.annotation.*;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 用户账户
 * </p>
 *
 * @author GodMeowIceSun
 * @since 2021-11-02
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("account")
@ApiModel(value = "Account对象", description = "用户账户")
public class AccountPO implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "ID")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty(value = "用户身份证")
    @TableField("id_card")
    private String idCard;

    @ApiModelProperty(value = "账户密码")
    @TableField("account_password")
    private String accountPassword;

    @ApiModelProperty(value = "用户姓名")
    @TableField("user_name")
    private String userName;

    @ApiModelProperty(value = "用户电话")
    @TableField("user_phone")
    private String userPhone;

    @ApiModelProperty(value = "用户地址")
    @TableField("user_address")
    private String userAddress;

    @ApiModelProperty(value = "用户工作")
    @TableField("user_job")
    private String userJob;

    @ApiModelProperty(value = "加密盐")
    @TableField("account_salt")
    private String accountSalt;

    @ApiModelProperty(value = "账户状态(0:未激活, 1:正常, 2:冻结)")
    @TableField("account_status")
    private Integer accountStatus;

    @ApiModelProperty(value = "账户余额")
    private BigDecimal balance;

    @ApiModelProperty(value = "创建时间, 开户时间")
    @TableField(value = "create_time", fill = FieldFill.INSERT)
    private LocalDateTime createTime;


}
